<?php // content="text/plain; charset=utf-8"
require_once ('../../../includes/jpgraph/jpgraph.php');
require_once ('../../../includes/jpgraph/jpgraph_bar.php');


//$datay=array($_GET["camb"],$_GET["cab"],$_GET["cas"],$_GET["cana"]);
$datay=array(100);
$datax=array(100);
$count=0;
foreach($_GET as $key => $value)
{
    $datay[$count]=$value;
    $datax[$count]=$key;
    
    $count++;    
}

//$datos = Distribucion_DB::obten_estadisticas_profesorArray($_GET["id"]);
// $_GET["profesores_estadisticas"];


// Create the graph. These two calls are always required
$graph = new Graph(550,220,'auto');
$graph->SetScale("textlin");

//$theme_class="DefaultTheme";
//$graph->SetTheme(new $theme_class());

// set major and minor tick positions manually
//$graph->yaxis->SetTickPositions(array(0,10,20,30,40,50), array(0,5,15,25,35,45));
//$graph->yaxis->SetTickPositions($datay, array(0,5,15,25,35,45));

$graph->SetBox(false);

//$graph->ygrid->SetColor('gray');
$graph->ygrid->SetFill(false);
//$graph->xaxis->SetTickLabels(array('MB','B','S','NA'));
$graph->xaxis->SetTickLabels($datax);
$graph->yaxis->HideLine(false);
$graph->yaxis->HideTicks(false,false);

// Create the bar plots
$b1plot = new BarPlot($datay);

// ...and add it to the graPH
$graph->Add($b1plot);


$b1plot->SetColor("white");
$b1plot->SetFillGradient("#4B0082","white",GRAD_LEFT_REFLECTION);
$b1plot->SetWidth(45);
$graph->title->Set("Materia por profesor");

// Display the graph
$graph->Stroke();
?>
